<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
	<head>
		<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
		<title>无标题文档</title>
		<link href="__STATIC__/Admin/css/style.css" rel="stylesheet" type="text/css" />
		<script type="text/javascript" src="__STATIC__/Admin/js/jquery.js"></script>		
	</head>

	<body>
		<div class="place">
			<span>位置：</span>
			<ul class="placeul">
				<li><a href="#">商品管理</a></li>
				<li><a href="#">类型管理</a></li>
				<li><a href="#">类型列表</a></li>
				<li><a href="#">属性列表</a></li>
			</ul>
		</div>

		<div class="rightinfo">
			<div class="tools">
				<ul class="toolbar">
					<li class="click">
						<a href="{|U:'Add',array('tid'=>$_GET['tid'])}">
							<span>
	        						<img src="__STATIC__/Admin/images/t01.png" />
	        					</span>添加属性
						</a>
					</li>
				</ul>
			</div>

			<table class="tablelist">
				<thead>
					<tr>
						<th>属性ID</th>
						<th>属性名称</th>
						<th>类别</th>
						<th>属性值</th>
						<th>操作</th>
					</tr>
				</thead>
				<tbody>
					<if value="count($data) == 0">	
						<tr>
							<td colspan="5" align="center">
								还没有属性数据，赶快<a href="{|U:'Add',array('tid'=>$_GET['tid'])}" class="tablelink"> 添加 </a>吧
							</td>
						</tr>
					<else/>
						<foreach from="$data" key="$k" value="$v">
							<tr>
								<td>{$v.taid}</td>
								<td>{$v.taname}</td>
								<td>
									<if value="$v['taclass']==0">属性<else/>规格</if>
								</td>
								<td>{$v.tavalue}</td>
								<td>
									<a href="{|U:'Edit', array('taid'=>$v['taid'],'tid'=>$v['tid'])}" class="tablelink">修改</a>
									<a href="{|U:'Del', array('taid'=>$v['taid'],'tid'=>$v['tid'])}" class="tablelink" onclick="if (!confirm('确认要删除吗？')) return false;">删除</a>
								</td>
							</tr>					
						</foreach>
					</if>
				</tbody>
			</table>

			<script type="text/javascript">
				$('.tablelist tbody tr:odd').addClass('odd');
			</script>

	</body>

</html>